import { MapEntryType } from './Home'
const { ccclass, property } = cc._decorator;
import storage from './helper/DATA/localstorage'
@ccclass
export default class NewClass extends cc.Component {

    @property(cc.Label)
    label: cc.Label = null;

    @property
    text: string = 'hello';

    // LIFE-CYCLE CALLBACKS:

    onLoad() {
        const current = storage.get('currentGame')
        const entry = current ? MapEntryType[current] : 'home'
        cc.director.loadScene(entry)
    }
}
